function [score errmx] = evaluate(net, data, labels)
	
	if(max(labels)==9)
		labels=labels.+1;
	end;

	classNo = size(unique(labels),1);
	errmx=zeros(classNo, classNo+1);
	answers = tellClass(data, net);
	indices = [labels, answers];
	
	for(i=1:size(indices,1))
		errmx(indices(i,1),indices(i,2))+=1;
	end
	score=sum(answers==labels)/size(labels,1);
end;
